package com.yubest.demo.dto;

import com.yubest.demo.validator.Length;
import com.yubest.demo.validator.RangeEnum;
import lombok.Data;

import java.io.Serializable;

/**
 * @Author hweiyu
 * @Description
 * @Date 2021/3/1 14:01
 */
@Data
public class Demo2DTO implements Serializable {

    private static final long serialVersionUID = 1019466745376831818L;

    @Length(min = 1, max = 5, message = "字段c长度在1到5个字符之间")
    private String c;

    @RangeEnum(allowableValues = {"x", "y"}, message = "字段d允许取值为:x,y")
    private String d;

}
